<template>
	<div id="home">
		<!-- 万木智会医生PC端 -->
		<menuPage class="menuPage" v-if="show"></menuPage>
		<div class="content">
			<contHeader class="contHeader" v-if="show"></contHeader>
			<router-view class="view" element-loading-spinner="el-icon-loading"></router-view>
		</div>
	</div>
</template>

<script>
	// import {} from '@/request/api.js';
	import menuPage from '@/components/menuPage.vue';
	import contHeader from '@/components/contHeader.vue';
	export default {
		name: 'home',
		components: {
			menuPage,
			contHeader
		},
		data() {
			return {
				activeIndex: '1',
        show: true,
				avatar: '',
			}
		},
		created() {

      if(this.$route.query.sign){
        let tokenObj= JSON.stringify({token: this.$route.query.sign});
        console.log("home",tokenObj);
        this.show = false;
      }else {
        console.log("home没有值")
      }

    },
		mounted() {
    },
		methods: {
			ligin() {
				this.$router.push({
					name: 'login'
				})
			}
		}
	}
</script>
<style lang="scss" scoped>
	#home {
		height: 100vh;
		display: flex;

		.menuPage {
			// height: calc(100% - 20px);
		}

		.content {
			flex: 1;
			display: flex;
			overflow: hidden;
			flex-direction: column;
			// padding: 20px 20px 20px 0;

			.view {
				flex: 1;
				overflow-y: auto;
				background-color: #fff;
				// border-radius: 10px;
			}
		}
	}
</style>